package com.eascs.ticket.ticket.vo;

import java.util.HashMap;
import java.util.Map;

public class GroupByHelper {
	private static final Map<String, String> GROUP_BY_EXPRESSION_MAP = new HashMap<>();
	static {
		GROUP_BY_EXPRESSION_MAP.put(GroupByConstant.GROUP_BY_VERSION, "vtitle");
		GROUP_BY_EXPRESSION_MAP.put(GroupByConstant.GROUP_BY_CREATOR, "creator");
		GROUP_BY_EXPRESSION_MAP.put(GroupByConstant.GROUP_BY_OPERATOR, "operator_name");
		GROUP_BY_EXPRESSION_MAP.put(GroupByConstant.GROUP_BY_PROJECT, "pname");
	}

	public static String getGroupExpression(String groupBy) {
		return GROUP_BY_EXPRESSION_MAP.get(groupBy);
	}

}
